#include "headers.h"
#include "Core.h"

using namespace std;
using namespace Engine;

int print(int x1)
	{
	cout << "x1: " << x1 << endl;
	}
int print4(int x1, int x2, int x3, int x4)
	{
	cout << "x1: " << x1;
	cout << " x2: " << x2;
	cout << " x3: " << x3;
	cout << " x4: " << x4 << endl;
	}

int main(void)
	{
	cout << "[Start]\n";
	Core *core = Core::getInstance();
	Window *window = reinterpret_cast<Window*>(core->moduleManager->getModule(WINDOW));
	core->moduleManager->print();
	window->onCreate.addListener(window, bind(print, std::placeholders::_1));
	window->onClose.addListener(window, bind(print4, std::placeholders::_1,std::placeholders::_2,std::placeholders::_3,std::placeholders::_4));
	window->create();
	cout << "\n[End]\nPress any key to exit program";
	//core->run();
	cin.get();
	return 0;
	}
